package com.media.entrance.model;

import java.util.Date;

// 跟db操作有关的实体
public class MatchInfo {

    public String getAgentId() {
        return agentId;
    }

    public void setAgentId(String agentId) {
        this.agentId = agentId;
    }

    public String getAgentStatus() {
        return agentStatus;
    }

    public void setAgentStatus(String agentStatus) {
        this.agentStatus = agentStatus;
    }

    public String getDeviceId() {
        return deviceId;
    }

    public void setDeviceId(String deviceId) {
        this.deviceId = deviceId;
    }

    public Date getTimestamp() {
        return timestamp;
    }

    public void setTimestamp(Date timestamp) {
        this.timestamp = timestamp;
    }

    public String getRoomId() {
        return roomId;
    }

    public void setRoomId(String roomId) {
        this.roomId = roomId;
    }

    //坐席工号
    private String agentId;

    //匹配的状态
    private String agentStatus;

    //匹配的设备号
    private String deviceId;

    //匹配的时间戳
    private Date timestamp;
    public MatchInfo(){

    }
    public MatchInfo(String agentId, String agentStatus, String deviceId, String roomId) {
        this.agentId = agentId;
        this.agentStatus = agentStatus;
        this.deviceId = deviceId;
        this.roomId = roomId;
    }

    //匹配后生成的房间ID
    private String roomId;

    @Override
    public String toString(){
        return "agentId:[" + agentId + "],agentStatus:[" + agentStatus + "], current deviceId:[" + deviceId + "],current roomId:[" + roomId + "]";
    }

    public MatchAndResourceModel changeToMatchAndResourceModel() {
        MatchAndResourceModel result = new MatchAndResourceModel();
        result.setAgentId(this.agentId);
        result.setAgentStatus(this.agentStatus);
        result.setDeviceId(this.deviceId);
        result.setRoomId(this.roomId);
        return result;
    }
}
